package com.cj.mobile.iabp.mvp.ui.adapter;

import android.view.View;

import com.cj.mobile.iabp.R;
import com.cj.mobile.iabp.mvp.ui.holder.SignInImgListItemHolder;
import com.jess.arms.base.BaseHolder;
import com.jess.arms.base.DefaultAdapter;

import org.jetbrains.annotations.NotNull;

import java.util.List;

/**
 * 包名： com.zqw.mobile.operation.mvp.ui.adapter
 * 对象名： SignInImgListAdapter
 * 描述：图片列表 适配器
 * 作者： wly
 * 邮箱：wangliyang206@163.com
 * 创建日期： 2021/1/20 16:53
 */

public class SignInImgListAdapter extends DefaultAdapter<String> {

    // 是否显示
    private boolean isShow;

    public SignInImgListAdapter(List<String> infos) {
        super(infos);
    }

    @NotNull
    @Override
    public BaseHolder<String> getHolder(@NotNull View v, int viewType) {
        return new SignInImgListItemHolder(v);
    }

    @Override
    public void onBindViewHolder(BaseHolder<String> holder, int position) {
        ((SignInImgListItemHolder) holder).initView(isShow);
        super.onBindViewHolder(holder, position);
    }

    @Override
    public int getLayoutId(int viewType) {
        return R.layout.signin_item_camera_layout;
    }

    public boolean isShow() {
        return isShow;
    }

    public void setShow(boolean show) {
        isShow = show;
    }

}
